import java.util.Scanner;

public class ReadNumberAndString {
    public static void main(String[] args){
    	  Scanner kbScanner = new Scanner(System.in);
    	  String line;
        double number;
        System.out.println("Enter a number: ");
        number = kbScanner.nextDouble();
        kbScanner.nextLine();      // dummy nextLine to remove \n or \r\n from the input buffer.
        System.out.println("Enter a line: ");
        line = kbScanner.nextLine();    
        System.out.println("The number is: " + number + ", the line is: " + line);
    }
}
